package com.woniu.p2p.excelservice;

import com.woniu.p2p.entity.UserScore;
import com.woniu.p2p.mapper.UserScoreMapper;
import com.woniu.p2p.vo.ImportScoreVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author 86152
 * @create 2020/8/15
 * @since 1.0.0
 */
@Service
public class InScoreService {
    @Autowired
    UserScoreMapper userScoreMapper;

    public void readExcel(ImportScoreVo importScoreVo) {
        UserScore userScore = new UserScore();
        userScore.setScoreAmount(importScoreVo.getScoreAmount());
        userScore.setScoreContext(importScoreVo.getScoreContext());
        userScore.setScoreBalance(importScoreVo.getScoreBalance());
        userScore.setScoreUname(importScoreVo.getScoreUname());
        userScore.setScoreStatus(importScoreVo.getScoreStatus());
        userScore.setUserid(importScoreVo.getUserid());
        userScore.setScoreTime(importScoreVo.getScoreTime());
        userScoreMapper.insert(userScore);
    }
}
